package com.zjuee.base.model.common.auth;

import com.alibaba.fastjson.annotation.JSONField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.zjuee.base.model.Base;
import lombok.*;
import lombok.experimental.Accessors;

import java.util.Date;

/**
 * @author wu liang
 * @since 1.0
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Accessors(chain = true)
@ToString(callSuper = true)
@EqualsAndHashCode(callSuper = true)
@TableName(value = "sys_menu")
public class Menu extends Base {

    //节点类型：1模块 2操作（操作节点必须要填写menuUrl）
    private Byte nodeType;

    //节点名称
    private String menuName;

    //路由url
    private String router;

    //受保护的url，对应服务端某个方法的请求路径
    private String menuUrl;

    //资源代码
    private String menuCode;

    //图标
    private String icon;

    //是否显示
    private Boolean isShow;

    //排序字段
    private Integer sort;

    @JSONField(serialize = false)
    private Date gmtCreate;

    @JSONField(serialize = false)
    private Date gmtModify;

    @JSONField(serialize = false)
    private Long createId;

    @JSONField(serialize = false)
    private Long modifyId;

    //级别
    private String levelCode;
}
